package org.particles.domain.world;

import java.util.List;

import org.particles.common.CommonUtil;
import org.particles.domain.field.AttractionForce;
import org.particles.domain.field.Field;
import org.particles.domain.field.RejectionForce;

/**
 * contains all available fields for simulations.
 */
public interface FieldRepository {
	/**
	 * rejection field with linear distance function.
	 * uses {@link RejectionForce RejectionForce}.
	 */
	public static final long REJECT_LIN = CommonUtil.uniqueBit();
	/**
	 * attraction field with exponential distance function.
	 * uses {@link AttractionForce AttractionForce}.
	 */
	public static final long ATTRACT_EXP = CommonUtil.uniqueBit();
	/**
	 * attraction field with linear distance function.
	 * uses {@link AttractionForce AttractionForce}.
	 */
	public static final long ATTRACT_LIN = CommonUtil.uniqueBit();
	public static final long STRING = CommonUtil.uniqueBit();
	
	void findFields(long fieldMarkers, List<Field> searchResult);
	Field getField(long fieldMarker);
	void addField(long fieldMarker, Field field);
}
